package org.fengdi.order.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.Getter;
import lombok.Setter;

@Data
@TableName("order")
@Getter
@Setter
public class Order {
    @TableId(type = IdType.AUTO)
    public int id;

    @TableField("user_id")
    public String userId;

    @TableField("commodity_code")
    public String commodityCode;

    @TableField("count")
    public Integer count;

    @TableField("money")
    public Float money;

    public Order(String userId, String commodityCode, Integer count, Float money) {
        this.userId = userId;
        this.commodityCode = commodityCode;
        this.count = count;
        this.money = money;
    }
}
